package types

import "fmt"

type MysqlConfig struct {
	Database string `json:"database"`
	Host     string `json:"host"`
	Port     string `json:"port"`
	Username string `json:"username"`
	Password string `json:"password"`
}

func (m *MysqlConfig) Identifier() string {
	return fmt.Sprintf("%s:%s:%s", m.Host, m.Port, m.Database)
}

type MongoConfig struct {
	Database string `json:"database" yaml:"database"`
	Host     string `json:"host" yaml:"host"`
	Port     string `json:"port" yaml:"port"`
	Username string `json:"username" yaml:"username"`
	Password string `json:"password" yaml:"password"`
}

func (m *MongoConfig) Identifier() string {
	return fmt.Sprintf("%s:%s:%s", m.Host, m.Port, m.Database)
}
